package com.sc.nft.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.sc.nft.entity.UserInfo;
import com.sc.nft.entity.vo.*;
import com.sc.nft.enums.IncomeHierarchyEnum;
import com.sc.nft.enums.ReceivedCollectionType;

import java.util.List;
import com.sc.nft.exception.GlobalException;

import java.util.Date;

public interface DaoService {


    /**
     *  判断用户是否升级
     * @param collectionId
     * @param userId
     * @param type
     */
    void upgrade(Long collectionId, Long userId, ReceivedCollectionType type);

    /**
     *  判断用户是否降级
     *  入口 :
     *  1.转增
     *  2.寄售
     * @param collectionId
     * @param userId
     */
    void downgrade(Long collectionId,Long userId,ReceivedCollectionType type );

    /**
     * 获取用户玛特dao页面
     * @param userInfo
     */
    UserDaoVO getUserDaoDetails(UserInfo userInfo);

    /**
     *  获取升级权益列表
     * @return
     */
    DaoLevelVO getDaoLevelList();

    /**
     * 条件查询下级列表
     * @param id
     * @param time
     * @param holdToken
     * @param secondaryHoldToken
     * @return
     */
    Page getRecommendListByUser(Long id, String time, String holdToken, String secondaryHoldToken, Integer pageNo, Integer pageSize);

    /**
     * 获取用户玛特dao页面(H5)
     * @param userId
     */
    UserDaoVO getUserDaoDetailsByH5(Long userId);

    /**
     * 用户推荐列表(H5)
     * @param id
     * @param time
     * @param holdToken
     * @param secondaryHoldToken
     * @param pageNo
     * @param pageSize
     * @return
     */
    Page getRecommendListByUserH5(Long id, String time, String holdToken, String secondaryHoldToken, Integer pageNo, Integer pageSize);

    /**
     * 获取收益详情
     * @return
     */
    GetIncomeDetailsVO getIncomeDetails();
    GetIncomeDetailsVO getIncomeNewDetails();


    /**
     * 根据层级查询收益列表
     * @param incomeHierarchyEnum
     * @return
     */
    Page<IncomeDetailsVO> getIncomeListNewVersions(List<IncomeHierarchyEnum> incomeHierarchyEnum,Integer pageNo, Integer pageSize);
    Page<IncomeDetailsVO> getIncomeList(IncomeHierarchyEnum incomeHierarchyEnum, Integer pageNo, Integer pageSize);

    /**
     * 获取用户收益列表
     * @param incomeTypeEnum
     * @return
     */
    Page<UserIncomeDetailsVO> pageIncomeList(Integer incomeTypeEnum, String userTel, Date startDate, Date endDate, Integer pageNo, Integer pageSize) throws GlobalException;

}
